A Gödel machine is a self-improving optimal problem solver computer program invented by Jürgen Schmidhuber. It rewrites its own code when it can prove the new strategy is optimal.